package org.budo.support.java.awt.robot;

import java.awt.GraphicsDevice;
import java.awt.Point;
import java.awt.Rectangle;

/**
 * @author limingwei
 */
public interface BudoRobot {
    Point mousePoint();

    GraphicsDevice mousePointerDevice();

    int getScreenWidth();

    int getScreenHeight();

    /**
     * 截全屏
     */
    BudoImage screenCapture();

    /**
     * 指定区域截图
     */
    BudoImage screenCapture(int x, int y, int w, int h);

    /**
     * 指定左上右下两个点截图
     */
    BudoImage screenCapture(Point topLeft, Point bottomRight);

    /**
     * 指定区域截图
     */
    BudoImage screenCapture(Rectangle rectangle);

    /**
     * 屏幕某一个点的色值
     */
    int rgb(Point point);

    /**
     * 移动鼠标到指定位置
     */
    BudoRobot mouseMove(int x, int y);

    BudoRobot mouseMove(Point point);

    /**
     * 滚动滚轮 正数往下，负数往上
     */
    BudoRobot mouseWheel(int wheelAmt);

    /**
     * @param ms milliseconds
     */
    BudoRobot delay(int ms);

    BudoRobot clickLeft();

    BudoRobot clickRight();

    String getClipboardContents();

    BudoRobot clickCtrl();

    BudoRobot mouseClick(int key);

    BudoRobot pressLeft();

    BudoRobot releaseLeft();

    BudoRobot CTRL_C();

    int mousePointRgb();

    int rgb(Point point, GraphicsDevice device);

    BudoImage screenCapture(int x, int y, int w, int h, GraphicsDevice device);

    BudoRobot doubleClickLeft();
}